#ifndef HANDLERSENSOR_H
#define HANDLERSENSOR_H

#include <QObject>
#include <QGraphicsEllipseItem>
#include <QGraphicsLineItem>
#include "Aria.h"
#include "ArNetworking.h"

class handlerSensor : public QObject
{
    Q_OBJECT
public:
    explicit handlerSensor(QObject *parent = 0,ArClientBase *client=0);
    
signals:
    void signal_paint_ellipse(QGraphicsEllipseItem *);
    void signal_paint_line(QGraphicsLineItem *);
    void signal_remove_ellipse(QGraphicsEllipseItem *);
    void signal_remove_line(QGraphicsLineItem *);
    
public slots:

private:
    ArClientBase *handledClient;



    std::vector <QGraphicsEllipseItem *> laserpoints;
    std::vector <QGraphicsEllipseItem *> sonarpoints;

    char lasername[512];

    char sonarname[512];


    ArFunctor1C<handlerSensor,ArNetPacket *> getSensorListCB;
    ArFunctor1C<handlerSensor,ArNetPacket *> getSensorCurrentCB;


    void getSensorList(ArNetPacket *packet);
    void getSensorCurrent(ArNetPacket *packet);
    
};

#endif // HANDLERSENSOR_H
